<script src="js/proinfo/compact/projCompact.js"></script>
<aside class="lg-side">
	<div class="panel-heading tab-bg-dark-navy-blue okr-tab-head tab-right "></div>
	<div class="inbox-body mi-h8">
		<div class="row">
			<div class="col-lg-12">
				<section class="panel" style="margin-bottom:0;">
					<header class="panel-heading">
						合同信息
					</header>
					<div class="panel-body">
						<div class="form-group customerForm">
							<label class="col-sm-2 control-label">公司名称</label>
							<div class="col-sm-10">
								<select certus-required class="form-control" ng-model="contractInfo.compCode" base-company-pact="stscompSelect">
									<option ng-repeat="ss in contractInfo.compCodeSelect" value="{{ss.code}}">{{ss.name}}</option>
								</select>
							</div>
						</div>
						<div class="form-group customerForm">
							<label class="col-sm-2 control-label">客户名称</label>
							<div class="col-sm-10">
								<input type="text" custom-name-list="contractInfo.compactCusId,contractInfo.compactCusName,customerId" id = 'customerId' certus-required certus-an-limit-length="200"
									class="form-control" ng-model="contractInfo.compactCusName" placeholder="合同上的文本名称">
							</div>
						</div>

<!--						<div class="form-group customerForm">-->
<!--							<label class="col-sm-2 control-label">我司签约公司</label>-->
<!--							<div class="col-sm-10">-->
<!--								<input type="text" onkeydown="return banInputSapce(event);" class="form-control"-->
<!--									certus-an-limit-length="50" certus-required ng-model="contractInfo.contractSubject">-->
<!--							</div>-->
<!--						</div>-->

<!--						<div class="form-group customerForm">-->
<!--							<label class="col-sm-2 control-label">合同性质</label>-->
<!--							<div class="col-sm-10">-->
<!--								<select certus-required class="form-control" ng-model="contractInfo.characterCA">-->
<!--									<option ng-repeat="x in [{'name':'集成类','code':'集成类'},{'name':'非集成类','code':'非集成类'}]"-->
<!--										value="{{x.code}}">-->
<!--										{{x.name}}-->
<!--									</option>-->
<!--								</select>-->
<!--							</div>-->
<!--						</div>-->


						<div class="form-group customerForm">
							<label class="col-sm-2 control-label">合同编号</label>
							<div class="col-sm-10">
								<input type="text" class="form-control" certus-an-limit-length="50" certus-required
									ng-model="contractInfo.contractNo" placeholder="合同上的编号。若没有，建议使用客户名称加合同签订日期(年月日)输入，(50字以内)">
							</div>
						</div>

						<div class="form-group customerForm">
							<label class="col-sm-2 control-label">合同名称</label>
							<div class="col-sm-10">
								<input type="text" class="form-control" certus-an-limit-length="200" certus-required
									ng-model="contractInfo.contractName" onkeydown="return banInputSapce(event);" placeholder="合同上的文本名称">
							</div>
						</div>

						<div class="form-group customerForm">
							<label class="col-sm-2 control-label">签订人</label>
							<div class="col-sm-10">
								<input type="text" class="form-control" certus-an-limit-length="50"
									ng-model="contractInfo.contractSigner" onkeydown="return banInputSapce(event);" placeholder="我司签订人">
							</div>
						</div>

<!--						<div class="form-group customerForm">-->
<!--							<label class="col-sm-2 control-label">销售内部编号</label>-->
<!--							<div class="col-sm-10">-->
<!--								<input type="text" certus-an-limit-length="50" onkeydown="return banInputSapce(event);"-->
<!--									class="form-control" placeholder="如果填写销售内部编号，销售内部编号不能重复"  ng-model="contractInfo.salesInternalCode">-->
<!--							</div>-->
<!--						</div>-->

						<!--<div class="form-group customerForm">-->
							<!--<label class="col-sm-2 control-label">财务编号</label>-->
							<!--<div class="col-sm-10">-->
								<!--<input type="text" class="form-control" onkeydown="return banInputSapce(event);"-->
									<!--certus-an-limit-length-str="50" placeholder="如果填写财务编号，财务编号不能重复" ng-model="contractInfo.financialCode">-->
							<!--</div>-->
						<!--</div>-->

						<div class="form-group customerForm">
							<label class="col-sm-2 control-label">合同金额*</label>
							<div class="col-sm-10">
								<div class="input-group m-bot15">
									<span class="input-group-addon">￥</span>
									<input type="text" certus-an-limit-length-num="50" certus-required class="form-control"
										 ng-model="contractInfo.contractAmount">
									<span class="input-group-addon"> 元</span>
								</div>
							</div>
						</div>
<!--						<div class="form-group customerForm">-->
<!--							<label class="col-sm-2 control-label">软件收入金额</label>-->
<!--							<div class="col-sm-10">-->
<!--								<div class="input-group m-bot15">-->
<!--									<span class="input-group-addon">￥</span>-->
<!--									<input type="text" certus-an-limit-length-num="50"  class="form-control" ng-model="contractInfo.softIncome">-->
<!--									<span class="input-group-addon"> 元</span>-->
<!--								</div>-->
<!--							</div>-->
<!--						</div>-->
<!--						<div class="form-group customerForm">-->
<!--							<label class="col-sm-2 control-label">非软件收入金额</label>-->
<!--							<div class="col-sm-10">-->
<!--								<div class="input-group m-bot15">-->
<!--									<span class="input-group-addon">￥</span>-->
<!--									<input type="text" certus-an-limit-length-num="50" class="form-control" onkeyup="clearNoNum(this)"-->
<!--										onblur="clearNoNum(this)" ng-model="contractInfo.notSoftIncome">-->
<!--									<span class="input-group-addon"> 元</span>-->
<!--								</div>-->
<!--							</div>-->
<!--						</div>-->
<!--						<div class="form-group customerForm">-->
<!--							<label class="col-sm-2 control-label">合同签订时间</label>-->
<!--							<div class="col-sm-10">-->
<!--								<input id="time-3" type="text" class="form-control" certus-required-->
<!--									onkeydown="return banInputSapce(event);" ng-model="contractInfo.contractSignTime">-->
<!--							</div>-->
<!--						</div>-->
<!--						<div class="form-group customerForm">-->
<!--							<label class="col-sm-2 control-label">交付时间</label>-->
<!--							<div class="col-sm-10">-->
<!--								<input id="time-1" type="text" value="" class="form-control" certus-required-->
<!--									onkeydown="return banInputSapce(event);" ng-model="contractInfo.deliveryTime">-->
<!--							</div>-->
<!--						</div>-->
<!--						<div class="form-group customerForm">-->
<!--							<label class="col-sm-2 control-label">最终结算日期</label>-->
<!--							<div class="col-sm-10">-->
<!--								<input id="time-2" type="text" class="form-control" onkeydown="return banInputSapce(event);"-->
<!--									ng-model="contractInfo.finalDate">-->
<!--							</div>-->
<!--						</div>-->
<!--						<div class="form-group customerForm">-->
<!--							<label class="col-sm-2 control-label">交付地</label>-->
<!--							<div class="col-sm-10">-->
<!--								<input type="text" onkeydown="return banInputSapce(event);" certus-required certus-an-limit-length="50"-->
<!--									class="form-control" ng-model="contractInfo.deliveryTo">-->
<!--							</div>-->
<!--						</div>-->
<!--						<div class="form-group customerForm">-->
<!--							<label class="col-sm-2 control-label">合同关键条款</label>-->
<!--							<div class="col-sm-10">-->
<!--								<textarea class="form-control" onkeydown="return banInputSapce(event);" placeholder="字数限制(50字以内)"-->
<!--									certus-an-limit-length="50" certus-required ng-model="contractInfo.keyTerms"></textarea>-->
<!--							</div>-->
<!--						</div>-->
						<div class="form-group customerForm">
							<label class="col-sm-2 control-label">申请说明</label>
							<div class="col-sm-10">
								<textarea class="form-control" certus-an-limit-length="200" placeholder="字数限制(200字以内)"
									onkeydown="return banInputSapce(event);" certus-required
									ng-model="contractInfo.applyInstruction"></textarea>
							</div>
						</div>

<!--						<div class="form-group customerForm">-->
<!--							<label class="col-sm-2 control-label">付款条款*</label>-->
<!--							<div class="col-sm-10">-->
<!--								<div class="input-group m-bot15">-->
<!--									<span class="input-group-addon">首付款</span>-->
<!--									<input type="text" certus-an-limit-length-num="5" ng-change="moneyChange(contractInfo.preliminaryInspection,'#time-11','initialPayment')" certus-required class="form-control"-->
<!--										ng-model="contractInfo.initialPayment" >-->
<!--									<span class="input-group-addon">%</span>-->
<!--								</div>-->
<!--							</div>-->
<!--						</div>-->

<!--						<div class="form-group customerForm"  ng-if="contractInfo.initialPayment && contractInfo.initialPayment > 0.00">-->
<!--							<label class="col-sm-2 control-label">首付款日期</label>-->
<!--							<div class="col-sm-10">-->
<!--								<input id="time-11" onfocus="initDate(this,'#time-11','initialPayment')" ocus="initDate('#time-11','initialPayment')" type="text" class="form-control" onkeydown="return banInputSapce(event);"-->
<!--									   ng-model="contractInfo.initialPaymentDate" certus-required>-->
<!--							</div>-->
<!--						</div>-->

<!--						<div class="form-group customerForm">-->
<!--							<label class="col-sm-2 control-label"></label>-->
<!--							<div class="col-sm-10">-->
<!--								<div class="input-group m-bot15">-->
<!--									<span class="input-group-addon">初验</span>-->
<!--									<input type="text" certus-an-limit-length-num="5" certus-required class="form-control"-->
<!--										ng-model="contractInfo.preliminaryInspection" ng-change="moneyChange(contractInfo.preliminaryInspection,'#time-12','preliminaryInspection')">-->
<!--									<span class="input-group-addon">%</span>-->
<!--								</div>-->
<!--							</div>-->
<!--						</div>-->

<!--						<div class="form-group customerForm" ng-if="contractInfo.preliminaryInspection && contractInfo.preliminaryInspection > 0.00">-->
<!--							<label class="col-sm-2 control-label">初验日期</label>-->
<!--							<div class="col-sm-10">-->
<!--								<input id="time-12" type="text" onfocus="initDate(this,'#time-12','preliminaryInspection')" class="form-control" onkeydown="return banInputSapce(event);"-->
<!--									   ng-model="contractInfo.preliminaryInspectionDate" certus-required>-->
<!--							</div>-->
<!--						</div>-->

<!--						<div class="form-group customerForm">-->
<!--							<label class="col-sm-2 control-label"></label>-->
<!--							<div class="col-sm-10">-->
<!--								<div class="input-group m-bot15">-->
<!--									<span class="input-group-addon">终验</span>-->
<!--									<input type="text" certus-an-limit-length-num="5" ng-change="moneyChange(contractInfo.preliminaryInspection,'#time-13','finalAcceptance')" certus-required class="form-control"-->
<!--										ng-model="contractInfo.finalAcceptance">-->
<!--									<span class="input-group-addon">%</span>-->
<!--								</div>-->
<!--							</div>-->
<!--						</div>-->

<!--						<div class="form-group customerForm" ng-if="contractInfo.finalAcceptance && contractInfo.finalAcceptance > 0.00">-->
<!--							<label class="col-sm-2 control-label">终验日期</label>-->
<!--							<div class="col-sm-10">-->
<!--								<input id="time-13" type="text" class="form-control" onfocus="initDate(this,'#time-13','finalAcceptance')" onkeydown="return banInputSapce(event);"-->
<!--									   ng-model="contractInfo.finalAcceptanceDate" certus-required>-->
<!--							</div>-->
<!--						</div>-->

<!--						<div class="form-group customerForm">-->
<!--							<label class="col-sm-2 control-label"></label>-->
<!--							<div class="col-sm-10">-->
<!--								<div class="input-group m-bot15">-->
<!--									<span class="input-group-addon">尾款</span>-->
<!--									<input type="text" certus-an-limit-length-num="5" ng-change="moneyChange(contractInfo.preliminaryInspection,'#time-14','finalPayment')" certus-required class="form-control"-->
<!--										ng-model="contractInfo.finalPayment">-->
<!--									<span class="input-group-addon">%</span>-->
<!--								</div>-->
<!--							</div>-->
<!--						</div>-->

<!--						<div class="form-group customerForm" ng-if="contractInfo.finalPayment && contractInfo.finalPayment > 0.00">-->
<!--							<label class="col-sm-2 control-label">尾款日期</label>-->
<!--							<div class="col-sm-10">-->
<!--								<input id="time-14" type="text" class="form-control" onfocus="initDate(this,'#time-14','finalPayment')" onkeydown="return banInputSapce(event);"-->
<!--									   ng-model="contractInfo.finalPaymentDate" certus-required>-->
<!--							</div>-->
<!--						</div>-->

<!--						<div class="form-group customerForm">-->
<!--							<label class="col-sm-2 control-label">合同份数</label>-->
<!--							<div class="col-sm-10">-->
<!--								<input type="text" certus-an-limit-length-num="3" class="form-control" certus-required-->
<!--									ng-model="contractInfo.contractNumber" onkeyup="value=value.replace(/^(0+)|[^\d]+/g,'')">-->
<!--							</div>-->
<!--						</div>-->
						<!--<div class="form-group customerForm">
                            <label class="col-sm-2 control-label">中标通知书</label>
                            <div class="col-sm-10">
                                <input type="file" value="" class="form-control" ng-model="contractInfo.isWinning">
                            </div>
                        </div>-->

						<p class="default-buttons">
							<a href="javascript:void(0);" class="button-back btn btn-info" onclick="disProjContactInfo()">返回</a>
							<a href="javascript:void(0);" class="button-next  btn btn-info" ng-click="alterInfoSubmit()">提交</a>
						</p>
					</div>
				</section>
			</div>
		</div>
	</div>
</aside>

<script>
	var picker1 = $('#time-1').datetimepicker({
		format: 'YYYY-MM-DD',
		locale: moment.locale('zh-cn')
	}).on('dp.change', function (e) {
		var result = new moment(e.date).format('YYYY-MM-DD');
		if (result && !angular.isUndefined(result)) {
			$$scope.contractInfo.deliveryTime = result;
			$$scope.$apply();
		}
	})
	var picker2 = $('#time-2').datetimepicker({
		format: 'YYYY-MM-DD',
		locale: moment.locale('zh-cn')
	}).on('dp.change', function (e) {
		var result = new moment(e.date).format('YYYY-MM-DD');
		if (result && !angular.isUndefined(result)) {
			$$scope.contractInfo.finalDate = result;
			$$scope.$apply();
		}
	})

	var picker3 = $('#time-3').datetimepicker({
		format: 'YYYY-MM-DD',
		locale: moment.locale('zh-cn')
	}).on('dp.change', function (e) {
		var result = new moment(e.date).format('YYYY-MM-DD');
		if (result && !angular.isUndefined(result)) {
			$$scope.contractInfo.contractSignTime = result;
			$$scope.$apply();
		}
	})

    var picker31 = $('#time-11').datetimepicker({
        format: 'YYYY-MM-DD',
        locale: moment.locale('zh-cn')
    }).on('dp.change', function (e) {
        var result = new moment(e.date).format('YYYY-MM-DD');
        if (result && !angular.isUndefined(result)) {
            $$scope.contractInfo.initialPaymentDate = result;
            $$scope.$apply();
        }
    })

    var picker32 = $('#time-12').datetimepicker({
        format: 'YYYY-MM-DD',
        locale: moment.locale('zh-cn')
    }).on('dp.change', function (e) {
        var result = new moment(e.date).format('YYYY-MM-DD');
        if (result && !angular.isUndefined(result)) {
            $$scope.contractInfo.preliminaryInspectionDate = result;
            $$scope.$apply();
        }
    })

    var picker33 = $('#time-13').datetimepicker({
        format: 'YYYY-MM-DD',
        locale: moment.locale('zh-cn')
    }).on('dp.change', function (e) {
        var result = new moment(e.date).format('YYYY-MM-DD');
        if (result && !angular.isUndefined(result)) {
            $$scope.contractInfo.finalAcceptanceDate = result;
            $$scope.$apply();
        }
    })

    var picker34 = $('#time-14').datetimepicker({
        format: 'YYYY-MM-DD',
        locale: moment.locale('zh-cn')
    }).on('dp.change', function (e) {
        var result = new moment(e.date).format('YYYY-MM-DD');
        if (result && !angular.isUndefined(result)) {
            $$scope.contractInfo.finalPaymentDate = result;
            $$scope.$apply();
        }
    })
</script>